﻿using System;
using System.Data;
using System.Configuration;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Runtime.Serialization;

namespace AppServices
{
	[DataContract]
	public class OrdersClass
	{
		/// <summary>
		/// Create a new Orders object.
		/// </summary>
		/// <param name="orderID">Initial value of OrderID.</param>
		public OrdersClass(Orders orders)
		{
			Customer = new CustomersClass(orders.Customers);
			Freight = orders.Freight;
			OrderDate = orders.OrderDate;
			OrderID = orders.OrderID;
			RequiredDate = orders.RequiredDate;
			ShipAddress = orders.ShipAddress;
			ShipName = orders.ShipName;
			ShippedDate = orders.ShippedDate;
			ShipVia = orders.ShipVia;
		}

		[DataMember]
		public CustomersClass Customer
		{
			get;
			set;
		}

		[DataMember]
		public Nullable<decimal> Freight
		{
			get;
			set;
		}

		[DataMember]
		public Nullable<global::System.DateTime> OrderDate
		{
			get;
			set;
		}

		[DataMember]
		public int OrderID
		{
			get;
			set;
		}

		[DataMember]
		public Nullable<global::System.DateTime> RequiredDate
		{
			get;
			set;
		}

		[DataMember]
		public string ShipAddress
		{
			get;
			set;
		}

		[DataMember]
		public string ShipName
		{
			get;
			set;
		}

		[DataMember]
		public Nullable<global::System.DateTime> ShippedDate
		{
			get;
			set;
		}

		[DataMember]
		public Nullable<int> ShipVia
		{
			get;
			set;
		}
	}
}
